/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package DTO;

import java.util.Date;

public class CTon_Kho extends CId{
    public CTon_Kho(){
        this.tonDau = 0;
        Date d = new Date();
        this.thang = d.getMonth();
        this.nam = d.getYear();
        this.soLuongNhap = 0;
        this.soLuongXuat = 0;
    }
    
    private int tonDau;
    public void setTonDau(int tondau){
        this.tonDau = tondau;
    }
    
    public int getTonDau(){
        return this.tonDau;
    }
    private int thang;
    public void setThang(int mm){
        this.thang = mm;
    }
    
    public int getThang(){
        return this.thang;
    }    
    private int nam;
    public void setNam(int nam){
        this.nam = nam;
    }
    public int getNam(){
        return this.nam;
    }
    
    private int tonToiThieu;
    private String tenSanPham;
    public void setTenSanPham(String tsp){
        this.tenSanPham = tsp;
    }
    
    public String getTenSanPham(){
        return this.tenSanPham;
    }
    
    public void setTonToiThieu(int ton_toi_thieu){
        this.tonToiThieu = ton_toi_thieu;
    }
    public int getTonToiThieu(){
        return this.tonToiThieu;
    }
    
    private int tonToiDa;
    public void setTonToiDa(int tontoida){
        this.tonToiDa = tontoida;
    }
    public int getTonToiDa(){
        return this.tonToiDa;
    }
    private long khoId;
    public void setKhoId(long id){
        this.khoId = id;
    }
    public long getKhoId(){
        return this.khoId;
    }
    
    private long sanPhamId;
    public void setSanPhamId(long id){
        this.sanPhamId = id;
    }
    public long getSanPhamId(){
        return this.sanPhamId;
    }    
    private int soluong;
    public void setSoLuong(int soluong){
        this.soluong = soluong;
    }
    public int getSoluong(){
        this.soluong = this.tonDau + this.soLuongNhap - this.soLuongXuat;
        return this.soluong;
    }
    private int soLuongNhap;
    public void setSoLuongNhap(int soluongnhap){
        this.soLuongNhap = soluongnhap;
    }
    public int getSoLuongNhap(){
        return this.soLuongNhap;
    }
    private int soLuongXuat;
    public void setSoLuongXuat(int slx){
        this.soLuongXuat = slx;
    }
    public int getSoLuongXuat(){
        return this.soLuongXuat;
    }    
}
